//Service统一出口
import AxiosUtils from './axios_utils'
import { BASE_URL, TIME_OUT } from './config'


const axiosUtils = new AxiosUtils({
    baseURL: BASE_URL,
    timeout: TIME_OUT,
    interceptors: {
        requestInterceptor: (config) => {
            console.log("单个实例请求拦截")
            return config
        },
        requestInterceptorCatch: (err) => {
            return err
        },
        responseInterceptor: (res) => {
            console.log("单个实例返回拦截")
            return res
        },
        responseInterceptorCatch(err) {
            return err;
        },
    }
})

export default axiosUtils